package sz.com.postoffice.jxyzwgcase.dao.master;

import org.apache.ibatis.annotations.Param;
import sz.com.postoffice.jxyzwgcase.dao.BaseDao;
import sz.com.postoffice.jxyzwgcase.pojo.ResourceMarket;

import java.util.List;

public interface ResourceMarketDao extends BaseDao<ResourceMarket> {
    void insertCampus(ResourceMarket resourceMarket);
    void insertEnterprise(ResourceMarket resourceMarket);
    void insertBuilding(ResourceMarket resourceMarket);
    void insertUptown(ResourceMarket resourceMarket);

    void updateCampus(ResourceMarket resourceMarket);
    void updateEnterprise(ResourceMarket resourceMarket);
    void updateBuilding(ResourceMarket resourceMarket);
    void updateUptown(ResourceMarket resourceMarket);

    void deleteCampusById(@Param("id") int id);
    void deleteEnterpriseById(@Param("id") int id);
    void deleteBuildingById(@Param("id") int id);
    void deleteUptownById(@Param("id") int id);

    void deleteCampusByCode(@Param("code") String code);
    void deleteEnterpriseByCode(@Param("code") String code);
    void deleteBuildingByCode(@Param("code") String code);
    void deleteUptownByCode(@Param("code") String code);

    ResourceMarket findCampusById(@Param("id") int id);
    ResourceMarket findEnterpriseById(@Param("id") int id);
    ResourceMarket findBuildingById(@Param("id") int id);
    ResourceMarket findUptownById(@Param("id") int id);

    List<ResourceMarket> findBuildingByListEntity(ResourceMarket resourceMarket);
    List<ResourceMarket> findCampusByListEntity(ResourceMarket resourceMarket);
    List<ResourceMarket> findEnterpriseByListEntity(ResourceMarket resourceMarket);
    List<ResourceMarket> findUptownByListEntity(ResourceMarket resourceMarket);
}
